
const _interopRequireDefault = require('@babel/runtime/helpers/interopRequireDefault');

exports.__esModule = true;
exports.default = void 0;

const _babelHelperVueJsxMergeProps = _interopRequireDefault(require('@vue/babel-helper-vue-jsx-merge-props'));

const _utils = require('../utils');

const _functional = require('../utils/functional');

// Utils
const _createNamespace = (0, _utils.createNamespace)('info');
const createComponent = _createNamespace[0];
const bem = _createNamespace[1];

function Info(h, props, slots, ctx) {
  const { dot } = props;
  const { info } = props;
  const showInfo = (0, _utils.isDef)(info) && info !== '';

  if (!dot && !showInfo) {
    return;
  }

  return h('div', (0, _babelHelperVueJsxMergeProps.default)([{
    class: bem({
      dot,
    }),
  }, (0, _functional.inherit)(ctx, true)]), [dot ? '' : props.info]);
}

Info.props = {
  dot: Boolean,
  info: [Number, String],
};

const _default = createComponent(Info);

exports.default = _default;
